package Modele;

import java.awt.Image;

public class TypeMonstre {

	private int type;
	private Image image;
	private static TypeMonstre[] typeMonstre = new TypeMonstre[7];
	private static int nbTypeMonstre = 0;
	
	public TypeMonstre(int t, Image img) {
		this.type = t;
		this.image = img;
		TypeMonstre.typeMonstre[TypeMonstre.nbTypeMonstre] = this;
		TypeMonstre.nbTypeMonstre ++;
	}
	
	public static Image getImage(int type) {
		int i;
		for (i = 0 ; i < TypeMonstre.typeMonstre.length ; i ++) {
			if (TypeMonstre.typeMonstre[i].type == type)
				break;
		}
		return TypeMonstre.typeMonstre[i].image;
	}
	
}